/**
 * Built-in Tools Index
 * 
 * Exports all built-in tools for easy registration
 */

import { calculatorTool, advancedCalculatorTool } from './calculator';
import {
  readFileTool,
  writeFileTool,
  listDirectoryTool,
  getFileInfoTool,
  searchFilesTool,
} from './file-tools';
import {
  executeJavaScriptTool,
  executePythonTool,
  executeShellTool,
  evaluateExpressionTool,
} from './code-execution';

/**
 * All built-in tools
 */
export const builtinTools = [
  // Calculator tools
  calculatorTool,
  advancedCalculatorTool,
  
  // File tools
  readFileTool,
  writeFileTool,
  listDirectoryTool,
  getFileInfoTool,
  searchFilesTool,
  
  // Code execution tools
  executeJavaScriptTool,
  executePythonTool,
  executeShellTool,
  evaluateExpressionTool,
];

/**
 * Tool categories for organization
 */
export const toolCategories = {
  calculator: [calculatorTool, advancedCalculatorTool],
  file: [readFileTool, writeFileTool, listDirectoryTool, getFileInfoTool, searchFilesTool],
  code: [executeJavaScriptTool, executePythonTool, executeShellTool, evaluateExpressionTool],
};

/**
 * Get tools by category
 */
export function getToolsByCategory(category: keyof typeof toolCategories) {
  return toolCategories[category] || [];
}

/**
 * Get all tool names
 */
export function getAllToolNames(): string[] {
  return builtinTools.map(tool => tool.name);
}

